const mongoose = require("mongoose")
const { Schema } = mongoose
const TokenWXs = mongoose.Schema({
    token: {
        type: String,
        required: true,
    },
    id_user: {
        type: Schema.Types.ObjectId,
        required: true,
        ref: "Users",
        unique: true,
    },
    createdAt: {
        type: Date,
        required: true,
        default: Date.now,
    },
}, { versionKey: false })

module.exports = mongoose.model("TokenWXs", TokenWXs, "TokenWXs")
